Hi,
compiler: mikroC Pro for PIC32 4.0.0
Board: mikromedia for PIC32 - with mikrobus shield
MCU: PIC32MX460F512L
I'm trying to configure the LoRa 3 click based on the provided example from the libstock package. I have an SDR, and I am able to see that it transmits three pulses upon initialization (so I know the module works), but when it tries to write to the eeprom to enable master mode it returns a 255 error code, which the documentation says is a header error. Could someone please help me explain what that means, and what could be the problem? I am using the exact example code, but with a usb uart3 click in slot 2 to enable logging over uart
Thank you!
LoRa 3 click header error
Re: LoRa 3 click header error
I have the exact same issue when using a mikromedia for STM with the same setup (mikroC pro form ARM though)
Re: LoRa 3 click header error
Okay, so turns out that the mikroBUS shield has the RX and TX pins wired to the same pins. Since the source code for the LoRa 3 click is not public, I have to assume the LoRa 4 source code that is on github is similar, as the cips are from the same manufacturer. After a command is sent to the chip it sends a response, always starting with 0xAA. The drivers read function reads the first byte it gets and checks if it matches the frame header, and fails if it does not. So when the tx pins on the USB UART click and the LoRa click are shared, the function recieves noise from the USB UART, and it will therefore fail.
I connected the clicks to a breadboard and wired up the pins to the mikromedia for PIC32 board, but with the tx pin of the usb uart disconnected, and it works just fine!
The question then is, is it possible to disable the uart tx pin of a mikrobus socket, to allow for using the LoRa 3 click alongside other clicks?
I connected the clicks to a breadboard and wired up the pins to the mikromedia for PIC32 board, but with the tx pin of the usb uart disconnected, and it works just fine!
The question then is, is it possible to disable the uart tx pin of a mikrobus socket, to allow for using the LoRa 3 click alongside other clicks?
- stefan.filipovic
- mikroElektronika team
- Posts: 1135
- Joined: 18 Dec 2018 10:30
Re: LoRa 3 click header error
Hi,
Unfortunately, you cannot disable the UART TX pin of a mikroBUS socket while it's used on another socket. All you can do is to physically remove the connection between USB UART click and TX pin (G4.5).
Kind regards,
Unfortunately, you cannot disable the UART TX pin of a mikroBUS socket while it's used on another socket. All you can do is to physically remove the connection between USB UART click and TX pin (G4.5).
Kind regards,
Stefan Filipović
Re: LoRa 3 click header error
Would it be possible to get the source code for the LoRa 3 click driver? This would allow me to improve on some of the functionality (like the blocking calls), without having to recreate the entire code
- stefan.filipovic
- mikroElektronika team
- Posts: 1135
- Joined: 18 Dec 2018 10:30