-- Leo's gemini proxy

-- Connecting to benjaminja.com:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini; lang=en-US

Communicating with my weatherstation


2023-06-24


#Side-Project

#Weather-Station


In my original plan for my weatherstation, I would wirelessly send weatherdata to a ground station. I have given up on this idea primarily because managing a rechargeable battery would introduce too many variables.


Now, I have decided to have a cable that connects between the ground station and the sensors. I will be using an ethernet cable as the medium, but I won’t be using the ethernet protocol. Having a network card on the station is more overhead than I would like.


The original plan was to connect the serial lines directly. This is not a great idea, since plain datalines cannot go a long distance without losing integrity. Instead, making the lines differential twisted pairs—which ethernet is already made of—would allow for longer reliable distance. I just don’t know how I would convert a line into a twisted differential pair.


I discovered that CAN bus could be the better option for me. It stands for Controller Area Network, and is designed to be a light weight alternative to Ethernet. CAN is generally used in cars and in industrial settings.


Now I just need to come up with a protocol to manage the weatherstation. I’ve discovered a protocol called CANopen which seems very interesting. I’m currently stuck trying to decide whether I want to fully implement CANopen, or if I want to develop my own protocol that is inspired from CANopen. There is a lot of stuff that goes on with CANopen that I don’t necessarily need (particularly since I don’t plan to integrate the weatherstation with other CANopen devices).


There is a library for CANopen called CANopenNode, however I would have to make my own compatibility layer with it since no has done that for the Teensy4.0. It might just be better for me to design my own partial CANopen library.


Maybe I’ve gone too far into CAN, and would have been better off just using an Ethernet card. I’ve had fun working with CAN and CANopen, so I don’t think I have wasted my own time here, but sometimes I wonder if it would have been better to use a different board that has ethernet built-in.



📭 Message me

📝Or mention this post

-- Response ended

-- Page fetched on Thu Jun 13 07:46:16 2024