Microchip PIC18F67J60 has an onboard Ethernet MAC and 10BASE-T PHY. This sample is MPLAB X + XC8 C on the classic Microchip TCP/IP Stack (MLA Ethernet demo)—not Arduino, not Python, not Zephyr. Same ingest JSON over the LAN HTTP→HTTPS relay.
The MLA stack does not ship a maintained HTTPS client for Cloudflare. Keep the MCU on HTTP to a Pi/NAS relay, same pattern as Uno + W5100 and STM32 Zephyr.
Parts
| Part | Why | Buy |
|---|---|---|
| PIC18F67J60 board | Onboard MAC + PHY + RJ45. PICkit / ICD for flash. | Microchip PIC18F67J60 · Amazon search |
| Waterproof DS18B20 | Default sample pin RD0 (change if your demo uses it). | Adafruit DS18B20 · Amazon |
| 4.7kΩ resistor | Pull-up to the board’s 1-Wire VDD (level-shift if IO is 5V-only). | Amazon 4.7k |
| Ethernet drop | DHCP or static IP in the MLA demo. Relay host on the same LAN. | Cat5e to your switch. |
Wiring
- DS18B20 VDD → board logic VDD (often 3.3V; check the demo schematic)
- DS18B20 GND → GND
- DS18B20 data → RD0, 4.7k pull-up (edit
OW_*macros if needed) - RJ45 → LAN. PICkit for flash; UART for 115200 logs
Build and flash
- Open Dashboard → Devices and download PIC18 main.c (ingest path filled in).
-
On a LAN host:
python3 sketches/relay/push_https_forward.py --listen 0.0.0.0:8080 \ --upstream https://thermaltrace.dev - Set
INGEST_HOSTto that machine (dotted IPv4). -
Install
MPLAB X
+ XC8. Open an MLA TCPIP Ethernet demo for PIC18F67J60, keep stack sources, add this module, call
ThermalTraceAppInit/ThermalTraceAppTaskfrom the demo main loop next toStackTask(), build, flash. - UART 115200: link/DHCP ok, then POST through the relay. Sensor key
temp1imports on first POST.
Repo drop-in:
sketches/microchip/pic18f67j60_ds18b20_ingest/
Related
Amazon buy links may include an Associates tag. Adafruit and other vendor links are direct (Adafruit does not run an affiliate program). ThermalTrace may earn a commission from qualifying Amazon purchases at no extra cost to you.
FAQ
Can a PIC18F67J60 post to ThermalTrace?
Yes. Drop-in MLA TCP/IP Stack C in MPLAB X: onboard Ethernet MAC/PHY, DS18B20 on RD0, HTTP to the LAN TLS relay. Guide: thermaltrace.dev/about/pic18-ethernet-ingest.
Why not HTTPS from the PIC?
The classic Microchip TCP/IP Stack does not ship a maintained HTTPS client for Cloudflare. The LAN relay keeps the MCU on HTTP, same as Uno W5100 and STM32 Zephyr.
Is this Arduino or XC8?
XC8 / MPLAB X on the MLA Ethernet demo. Not an Arduino .ino.