Closed IssamSayyaf closed 5 months ago
Just was a curious question just to be sure. Thank you, I am working to modify my code. A huge thanks
Not that it won't be a problem of course, I just can't see one ;-). LENA-R8 is full of surprises :-).
haha :) , I would like to ask a question, we are wondering, if we can connect the LENA R8 GNSS UART with another microcontroller Cortex-M4. The LTE will stay working on Linux, however, the GNSS connects it with Cortex-M. Is it possible, is it a good choice?
I have followed the instructions, however, I can't open the device—the error is -8.
Opened device with return code -8.
returnCode = uDeviceOpen(&gDeviceCfg, &devHandle); uPortLog("Opened device with return code %d.\n", returnCode); uCellCfgSetGnssProfile(devHandle, U_CELL_CFG_GNSS_PROFILE_USB_AUX_UART, NULL);
Obviously you will need to debug this to find out what would cause U_ERROR_COMMON_PLATFORM.
I moved to implement this example it works, but it looks like uses the same port for LTE, in I brought up the LTE, and then I tried to move to GNSS, Everything was good however, there is an error
+CME ERROR: Operation not supported AT+UGPS=1,15,127
+CME ERROR: Operation not supported AT+UGPS=1,15,127 .
I don't know if it is the right way to start, could you recommend an example to start developing it to make LENA work?
I feel I am stuck, if you can help me I will be thankful
without UART, use the same port I received message is not support, if you can guide me how can I make it run using UART I mean another port, I will be thankful
You can take that approach if you wish, but remember that it will not support "streamed" position from the GNSS device (i.e. none of the ubxlib
location/GNSS APIs with Streamed
in the name will work): calling uNetworkInterfaceUp()
on the cellular device will indeed use the same transport as uDeviceOpen()
created, either starting up CMUX to do so or, where CMUX is not supported [the LENA-R8 case], it will drop back to using AT+UGUBX
commands, which are not able to support streamed position from the GNSS device (as AT commands only do "polled" kind of behaviours).
The reason you are getting "+CME ERROR: Operation not supported" is likely because of the GNSS system selection number used at the end of the AT+UGPS
command: we set it to "all" and some GNSS-enabled-cellular modules then set all of the ones they support, ignoring ones they don't while other GNSS-enabled-cellular modules reject the number if it asks for GNSS system types that the GNSS chip inside the cellular module does not support. You can try setting U_CELL_LOC_GNSS_SYSTEM_TYPES to, say 3, for now, and see if that works.
Now, it is working, without this error unsupporting, however, still have a problen. Unable bring the GNSS This my modification // NETWORK configuration for GNSS static const uNetworkCfgGnss_t gNetworkCfg = { .type = U_NETWORK_TYPE_GNSS, .moduleType = U_CELL_LOC_GNSS_SYSTEM_TYPES, .devicePinPwr = -1, // The pins of the cellular module that are connected .devicePinDataReady = -1 // to the GNSS chip's power and Data Ready lines };
Ah, yes, I forget LENA-R8 does support CMUX, so the ubxlib
code will try to use it, LENA-R8 just doesn't support access to the built-in GNSS chip over CMUX. For this case you should do a clean build with U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY
defined and that will force ubxlib
to only use AT commands to talk to the GNSS chip built into the cellular module.
And if I want to have streaming, what should I do where should I move?
Because this will work on trucks so, I think the streaming will be important. Maybe latter, I will think about streaming but now for this what do you think the problem.
If you want streamed GNSS position then, as indicated above, you will need to debug why you were getting U_ERROR_COMMON_PLATFORM when you tried to call uDeviceOpen()
for the GNSS device on the auxiliary UART.
okay I will check latter, for the streaming.
Regarding this U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY , I didn't understand it.
Could you tell me what should I do for this "U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY"
I mean that you should do a clean build with the conditional compilation flag U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY
defined for the build.
Ah okay, got it. I will do it. Thank you very much
I have an error :) cc: warning: U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY: linker input file unused because linking not done cc: error: U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY: linker input file not found: No such file or directory make[2]: [CMakeFiles/ubxlib.dir/build.make:76: CMakeFiles/ubxlib.dir/home/root/LTE/ubxlib/common/at_client/src/u_at_client.c.o] Error 1 make[2]: Deleting file 'CMakeFiles/ubxlib.dir/home/root/LTE/ubxlib/common/at_client/src/u_at_client.c.o' make[1]: [CMakeFiles/Makefile2:85: CMakeFiles/ubxlib.dir/all] Error 2 make: [Makefile:91: all] Error 2
"linker input file not found: No such file or directory" is not an error I have ever seen or heard of I'm afraid. I would guess that you are not specifying the conditional compilation flag to your toolchain correctly...?
it is like this
export U_FLAGS="-DU_CFG_PPP_ENABLE -DU_CELL_PRIVATE_PPP_CONTEXT_ID_LENA_R8=-1 -DU U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY"
-DU U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY
doesn't look right to me...?
I think I fix it
it is the same
U_CELL: initialising with enable power pin not connected, PWR_ON pin not connected and VInt pin not connected. AT
OK AT
OK U_CELL_PWR: powering on, module is already on. ATE0
OK AT+CMEE=2
OK AT+UDCONF=1,0
OK ATI9
02.00,A01.22
OK AT&C1
OK AT&D0
OK AT&K0
OK AT+UPSV=0
OK AT+UGPRF?
+UGPRF:2,0,""
OK AT+CFUN=4
OK U_PORT_PPP: listening for pppd on socket 127.0.0.1:5000. Opened cellular device with return code 0. Bringing up GNSS... U_PORT_PPP: pppd has connected to socket. AT+CMUX=0,0,,128
OK ATE0 ATE0
OK AT+CMEE=2
OK Unable to bring up GNSS! U_PORT_PPP: pppd has been disconnected from socket. U_PORT_PPP: no longer listening for pppd on socket. Done.
Are you sure that was a clean build?
Yeah I removed the directory and mkdir new one, then I export then cmake, the make.
I will try again
You can see the code here:
If U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY
is defined execution should never get to line 216. You can try putting a debug print there to see what is happening.
I made like to told me U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY is not define
so it doesn't define the Flag this how I export
Are there any problem
export U_FLAGS="-DU_CFG_PPP_ENABLE -DU_CELL_PRIVATE_PPP_CONTEXT_ID_LENA_R8=-1 -U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY"
export U_FLAGS="-DU_CFG_PPP_ENABLE -DU_CELL_PRIVATE_PPP_CONTEXT_ID_LENA_R8=-1 -U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY"
I think you are missing a D
there.
God! sorry for this stupid mistake.
Okay, it looks like is going on the right way, I still have a problem
'U_NETWORK_GNSS_CFG_CELL_USE_AT_ONLY is define U_CELL: initialising with enable power pin not connected, PWR_ON pin not connected and VInt pin not connected. AT
OK AT
OK U_CELL_PWR: powering on, module is already on. ATE0
OK AT+CMEE=2
OK AT+UDCONF=1,0
OK ATI9
02.00,A01.22
OK AT&C1
OK AT&D0
OK AT&K0
OK AT+UPSV=0
OK AT+UGPRF?
+UGPRF:2,0,""
OK AT+CFUN=4
OK U_PORT_PPP: listening for pppd on socket 127.0.0.1:5000. Opened cellular device with return code 0. Bringing up GNSS... Unable to bring up GNSS! U_PORT_PPP: no longer listening for pppd on socket. Done'
OK, so now you need to get into the flow of debug. Do you have a debugger in your setup or are you just planning to use debug prints? If the former then you can put a break-point here:
...and from there step down into uGnssPwrOn()
to see what is happening. If the latter then you can insert debug prints at that point and then within uGnssPwrOn()
to find out the same thing.
Basically, get yourself set up for debugging and "do that thang", so to speak, as you would for any development.
Okay Okay, I think it will be better to make a real debug, I will use gdb, and then I will let you know.
Hello, I hope everything is fine
I had some Hw problem I have solved, currently I am able to receive NMEA message from the GNSS, the boudrate is 38400, however, I am trying to run one of your example, I am facing some problem, could you advice me which example and how can I use your framwork to receive and control with the GNSS, thank you very much.
It is connected on /dev/ttySTM2, however, I always, have a problem with framwork could you help me.
issam_LTE.txt I am working on this, however I don't know what is the problem
Hi there: it is a bit difficult to know how to help without knowing what the problem is. Looking at the code you have attached, the field .pPrefix
seems to be being initialised multiple times, which I'm surprised compiles:
.pPrefix = "/dev/ttySTM", // Prefix for the device file <<< THIS SEEMS CORRECT
.baudRate = 38400, /* Use 0 to try all possible baud rates and find the correct one. */
.pinTxd = U_CFG_APP_PIN_GNSS_TXD, // Use -1 if on Zephyr or Linux or Windows
.pinRxd = U_CFG_APP_PIN_GNSS_RXD, // Use -1 if on Zephyr or Linux or Windows
.pinCts = U_CFG_APP_PIN_GNSS_CTS, // Use -1 if on Zephyr
.pinRts = U_CFG_APP_PIN_GNSS_RTS, // Use -1 if on Zephyr
// <<< .pPrefix seems to be being initalised again, to what seem to be incorrect values, below >>>
#ifdef U_CFG_APP_UART_PREFIX
.pPrefix = U_PORT_STRINGIFY_QUOTED(U_CFG_APP_UART_PREFIX) // Relevant for Linux only
#else
.pPrefix = NULL
#endif
Hello,
I hope this message finds you well.
I am reaching out to seek your guidance on configuring the ubxlib library for use with the LEAN_R8 device on a Linux operating system. I have successfully cloned the repository and identified the specific components I need within the UBXLIB_FEATURES section of the linux.cmake file.
Following this, I executed the cmake command to configure the build environment and subsequently ran the test program, which performed as expected. However, my primary objective is to ensure that the compiled library is fully compatible with the LEAN_R8 device, which connects via USB and communicates using the Point-to-Point Protocol (PPP).
Could you please advise on the steps necessary to instruct the cmake build system to target the LEAN_R8 device specifically? My aim is to ensure seamless communication over USB with PPP protocol support. and if there are any examples of this.
I appreciate your time and look forward to your expert advice.