I want to use the 433MHz simple link and I need direct control to the TX pin to implement a custom line coding scheme used by some existing products. In order to do this I need relatively high speed access to the pin, since the bit length is about 500usec. It looks like the digital write used by the GrovePi library waits 10msec in the C# library – but not in the python library (?).
What’s the best way to go here: attempt to send i2c packets of digital writes and hope that I can turn the pin on and off quick enough, or add a custom i2c sensor that interprets an i2c packet and modulates it on the grovepi using digitalWrite there (Like the virtualwire lib but directly)? Unfortunately I can’t use the virtual wire support since that works on a slightly higher level and uses its own line coding and OTA packet format.
Have you considered connecting the tx module on the “RPi Serial” port? You could then directly access it from the raspberry pi, provided that you have no other use for this serial port…
In this setup I have used successfully the 433Utils library (a port of an Arduino lib) with this grove component. So it is indeed possible to address the TX module that way. This said, the protocol I have been using is not the same, and I am not expert enough in this field to tell you if you would be able to get something useful out of the UART port.
If this fails, you still have the option of making a custom firmware based on the existing one to implement your specific version of the protocol, in place of the vw one…
I confirm that I am using the Simple RF Kit, not the Serial RF Pro.
You will note that the Seeedstudio wiki description points that it is possible to use a UART port.
You can customize the 1.2.6 firmware to substitute the VW integration with your custom code.
Let me know if you need a few pointers to setup a work environment or extend the firmware.
That’s actually the kind of setup I had in mind.
Cross-compilation on PC, scp to the RPi and ssh command to upload the firmware with AvrDude.
I found that directly developing on the RPi was an exercice in frustration.
My own work environment is based on Jetbrains’ CLion, a professional C++ IDE way more powerful than the Arduino IDE. I’ve got a nice CMake makefile to handle all the cross-compilation / transfer / upload stuff in one ‘build’ click.
The occasional debugging is achieved by good old Serial.print, with a cross-cable between the serial and RPi serial ports of the GrovePi and minicom monitoring.