at-command

Manage serial port from two processes simultaneosly

半世苍凉 提交于 2021-02-17 05:28:25
问题 I have the following scenario: Rasperry pi connected to a device via Serial port 3g Dongle connected to the raspberry (with the ability to make/recieve calls) One process reading the data from the serial port and redirecting it to a server (using 3g) Another process waiting for a incoming call, and when someone calls the program takes the data from the serial port and redirect it via the 3g dongle using AT commands ( like fax-call). When someone calls, the call is made using AT commands and

How to get the SIM number (ICCID) of a modem using AT commands

我与影子孤独终老i 提交于 2021-02-07 06:51:17
问题 I'm trying to get the SIM number (ICCID, not IMSI) of my 3G Huawei E5830 modem using AT commands (also called Hayes command set ). Unfortunately, it's not specified in the modem formal documentation. 回答1: for sim900 AT+CCID gives CCID. e.g.89912200000280775659 The first two digits (89 in the example) refers to the Telecom Id. The next two digits (91 in the example) refers to the country code (91-India). The next two digits (22 in the example(MNC of IDEA)) refers to the network code. 回答2: Try

Conditionally replace values of multiple columns, from values of other multiple columns

有些话、适合烂在心里 提交于 2021-02-04 06:57:47
问题 Suppose I have this dataset: set.seed (1234); data.frame(cbind(a=rep(c("si","no"),30),b=rnorm(60)), c=rep(c("d","e","f"),20)) %>% head() Then I want to add many columns (in this example I only added two), to identify distinct cases between each group (in this case, column "a"). set.seed(1234); data.frame(cbind(a=rep(c("si","no"),30),b=rnorm(60)),c=rep(c("d","e","f"),20)) %>% group_by(a) %>% dplyr::mutate_at(vars(c(b,c)), .funs= list(dups_hash_ing= ~n_distinct(.))) This code leaves the

Conditionally replace values of multiple columns, from values of other multiple columns

心已入冬 提交于 2021-02-04 06:52:59
问题 Suppose I have this dataset: set.seed (1234); data.frame(cbind(a=rep(c("si","no"),30),b=rnorm(60)), c=rep(c("d","e","f"),20)) %>% head() Then I want to add many columns (in this example I only added two), to identify distinct cases between each group (in this case, column "a"). set.seed(1234); data.frame(cbind(a=rep(c("si","no"),30),b=rnorm(60)),c=rep(c("d","e","f"),20)) %>% group_by(a) %>% dplyr::mutate_at(vars(c(b,c)), .funs= list(dups_hash_ing= ~n_distinct(.))) This code leaves the

SIM800C GSM AT COMMAND How to upload .amr audio file programmatically

你说的曾经没有我的故事 提交于 2021-01-28 11:57:28
问题 I am desperatly trying to upload some audio file to the internal memory of a SIM800C, so far this is what I've been able to do, but the uploaded file seems void, and doesnt play any sound. But with AT+FSLS=C:\\ I can see the file is there. Here are the AT commands I am using: AT+FSCREATE=tts2.amr AT+FSWRITE=tts2.amr,0,5030,10 AT+FSLS=C:\\ I made a nodeJS program to do the job, but I am openned to any other language that works on linux. modem.executeCommand('AT+FSCREATE=tts2.amr',(result) => {

Sending AT commands to USR modem in C

只谈情不闲聊 提交于 2021-01-28 11:50:40
问题 I was wondering if any of you know what I'm doing wrong here? So I have this program in C, that sends AT commands to a modem. These commands have been tested on hyperterminal and work fine, but when sendind them through the modem I get, first, and "OK" for the first "AT" command, which is good, but then, upon sending the next command, the modem answers with "AT+CC"...which I have no idea what it means. Any help is appreciated. Source: void sendSMS(const char* port, const char* number, const

How the callback functions work in stm32 Hal Library?

岁酱吖の 提交于 2021-01-28 07:38:41
问题 As we all know,the Hal Lib provides some callback function to manage hardware interrupt.But i don't know how them work? Te fact is that I am using HAL_UART_RxCpltCallback(UART_HandleTypeDef *huart) this function so as to receive other devices' data and check those data.So I use the usart interrupt to receive them. But I don't know when the callback function will be executed,is it depends on the receive buffer's length or the data's buffer? I guess the hardware interrupt will be triggered

Websockets ESP8266

对着背影说爱祢 提交于 2021-01-28 04:52:42
问题 I'm trying to send data to a server with websocket in ESP8266, but the handshake don't work. I'm sending the following sequence of AT commands: AT+RST AT+CWMODE=1 AT+CIPMODE=0 AT+CIPMUX=1 AT+CWJAP="ssid_my_network","password" AT+CIPSTART=4,"TCP","ip_server",port AT+CIPSEND=4,data_lenght In this moment, i send the header: GET ws:ip_server HTTP/1.1\r\n Host: ip_server\r\n Upgrade: websocket\r\n Connection: Upgrade\r\n Sec-WebSocket-Key: dGhlIHNhbXBsZSBub25jZQ==\r\n Sec-WebSocket-Version: 13\r\n

AT+CPMS “SM” Storage

我与影子孤独终老i 提交于 2021-01-27 19:54:02
问题 AT+CPMS? query to a SIM returns +CPMS: "SM",0,60, "SM,0,60,"SM",0,60 OK The total storage is 60 messages maximum, and 0 are currently stored. All messages are stored on the SIM. An existing legacy application fails when trying to populate all 60 message boxes because message box 55 is the last successful write location. When trying to populate the spaces 56-60, the command returns CMS Error 322 which is a memory full error. The text in each SMS is simply "P H" which is 3 ASCII bytes, so each

How to send multipart/concatenated SMS to phone using AT command?

北城余情 提交于 2021-01-27 13:01:47
问题 I got a computer with a nokia hooked up to it, and using AT Commands I managed to send text messages through my C# program (using TEXT MODE AT COMMANDS, NOT PDU). It's all working fine and I can recieve messages as well. I do wish to be able to send a text thats longer than 160 characters. And for that I need to be able to send a multipart SMS. I've searched around for this and my mate has told me that I need to check the header information in bytes on my "long" message, I analyzed the header