Jump to content
Electronics-Lab.com Community

Search the Community

Showing results for tags 'android'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Electronics Forums
    • Projects Q/A
    • Datasheet/Parts requests
    • Electronic Projects Design/Ideas
    • Power Electronics
    • Service Manuals
    • Theory articles
    • Electronics chit chat
    • Microelectronics
    • Electronic Resources
  • Related to Electronics
    • Spice Simulation - PCB design
    • Inventive/New Ideas
    • Mechanical constructions/Hardware
    • Sell/Buy electronics - Job offer/requests
    • Components trade
    • High Voltage Stuff
    • Electronic Gadgets
  • General
    • Announcements
    • Feedback/Comments
    • General
  • Salvage Area

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Yahoo


Skype


Location


Interests

Found 4 results

  1. OTA Description OTA, short for Over-the-Air Technology, refers to the process in Android systems where mobile devices download and install updates directly via wireless networks (such as WiFi, 3G/4G/5G) from remote servers, without needing to connect to a computer, simplifying the upgrade process and enhancing user experience. Advantages of OTA The advantages of OTA (Over-the-Air) updates in the Android ecosystem are significant and well-appreciated. The primary reason for their popularity is the convenience and speed – users can upgrade their devices without connecting to a computer, simply by being on a network, which saves a considerable amount of time and effort. Simultaneously, OTA updates efficiently and automatically detect new versions and notify users, ensuring that their devices always operate on the latest, most secure system or applications. This not only simplifies the process of manually searching for and installing updates but also reduces the security risks associated with outdated versions. Consequently, OTA updates are vital for enhancing user experience, lowering operational costs, and ensuring the security of devices. How to implement Android OTA upgrade in imx8mp platform? Build the OTA upgrade package 1. Build the target file Enter the related path: forlinx@ubuntu:~$ cd imx8mp/OK8MP-android-source/ forlinx@ubuntu:~/imx8mp/OK8MP-android-source$ Configure the environment: forlinx@ubuntu:~/imx8mp/OK8MP-android-source$ source env.sh forlinx@ubuntu:~/imx8mp/OK8MP-android-source$ source build/envsetup.sh forlinx@ubuntu:~/imx8mp/OK8MP-android-source$ lunch evk_8mp-userdebug ============================================ PLATFORM_VERSION_CODENAME=REL PLATFORM_VERSION=11 TARGET_PRODUCT=evk_8mp TARGET_BUILD_VARIANT=userdebug TARGET_BUILD_TYPE=release TARGET_ARCH=arm64 TARGET_ARCH_VARIANT=armv8-a TARGET_CPU_VARIANT=cortex-a53 TARGET_2ND_ARCH=arm TARGET_2ND_ARCH_VARIANT=armv7-a-neon TARGET_2ND_CPU_VARIANT=cortex-a9 HOST_ARCH=x86_64 HOST_2ND_ARCH=x86 HOST_OS=linux HOST_OS_EXTRA=Linux-5.4.0-150-generic-x86_64-Ubuntu-18.04.4-LTS HOST_CROSS_OS=windows HOST_CROSS_ARCH=x86 HOST_CROSS_2ND_ARCH=x86_64 HOST_BUILD_TYPE=release BUILD_ID=RQ1A.201205.003 OUT_DIR=out PRODUCT_SOONG_NAMESPACES=device/generic/goldfish device/generic/goldfish-opengl external/mesa3d vendor/nxp-opensource/imx/power hardware/google/pixel vendor/partner_gms hardware/google/camera vendor/nxp-opensource/imx/camera ============================================ Start compiling: forlinx@ubuntu:~/imx8mp/OK8MP-android-source$ ./imx-make.sh bootloader kernel -j4 make: Entering directory '/home/forlinx/imx8mp/R3_6.28/OK8MP-android-source' /home/forlinx/imx8mp/R3_6.28/OK8MP-android-source/device/nxp/common/build/uboot.mk:74: *** shell env AARCH64_GCC_CROSS_COMPILE is not set. Stop. make: Leaving directory '/home/forlinx/imx8mp/R3_6.28/OK8MP-android-source' forlinx@ubuntu:~/imx8mp/OK8MP-android-source$ make target-files-package -j4 ============================================ PLATFORM_VERSION_CODENAME=REL PLATFORM_VERSION=11 TARGET_PRODUCT=evk_8mp TARGET_BUILD_VARIANT=userdebug TARGET_BUILD_TYPE=release TARGET_ARCH=arm64 TARGET_ARCH_VARIANT=armv8-a TARGET_CPU_VARIANT=cortex-a53 TARGET_2ND_ARCH=arm TARGET_2ND_ARCH_VARIANT=armv7-a-neon TARGET_2ND_CPU_VARIANT=cortex-a9 HOST_ARCH=x86_64 HOST_2ND_ARCH=x86 HOST_OS=linux HOST_OS_EXTRA=Linux-5.4.0-150-generic-x86_64-Ubuntu-18.04.4-LTS HOST_CROSS_OS=windows HOST_CROSS_ARCH=x86 HOST_CROSS_2ND_ARCH=x86_64 HOST_BUILD_TYPE=release BUILD_ID=RQ1A.201205.003 OUT_DIR=out PRODUCT_SOONG_NAMESPACES=device/generic/goldfish device/generic/goldfish-opengl external/mesa3d vendor/nxp-opensource/imx/power hardware/google/pixel vendor/partner_gms hardware/google/camera vendor/nxp-opensource/imx/camera ============================================ [……] #### build completed successfully (13:07 (mm:ss)) #### After the compilation is completed, it will generate "evk_8mp-/target_files-eng.forlinx.zip" under the path "out/target/product/evk_8mp/obj/PACKAGING/target_files_intermediates/".target_files-eng.forlinx.zip" in the path "evk_8mp-eng.forlinx.zip", this is the zip package we need for OTA upgrade. forlinx@ubuntu:~/imx8mp/OK8MP-android-source$ cd out/target/product/evk_8mp/obj/PACKAGING/target_files_intermediates/ forlinx@ubuntu:~/imx8mp/OK8MP-android-source/out/target/product/evk_8mp/obj/PACKAGING/target_files_intermediates$ ls evk_8mp-target_files-eng.forlinx evk_8mp-target_files-eng.forlinx.zip evk_8mp-target_files-eng.forlinx.zip.list Back up "evk_8mp-target_files-eng.forlinx.zip",rename to ''target_files_v1.0.zip'': forlinx@ubuntu:~/imx8mp/OK8MP-android-source/out/target/product/evk_8mp/obj/PACKAGING/target_files_intermediates$ cp evk_8mp-target_files-eng.forlinx.zip target_files_v1.0.zip forlinx@ubuntu:~/imx8mp/OK8MP-android-source/out/target/product/evk_8mp/obj/PACKAGING/target_files_intermediates$ ls evk_8mp-target_files-eng.forlinx evk_8mp-target_files-eng.forlinx.zip evk_8mp-target_files-eng.forlinx.zip.list target_files_v1.0.zip 2. Build a complete update package Configure the environment in the same way as in step 1. Compile command: forlinx@ubuntu:~/imx8mp/OK8MP-android-source$ make otapackage -j4 ============================================ PLATFORM_VERSION_CODENAME=REL PLATFORM_VERSION=11 TARGET_PRODUCT=evk_8mp TARGET_BUILD_VARIANT=userdebug TARGET_BUILD_TYPE=release TARGET_ARCH=arm64 TARGET_ARCH_VARIANT=armv8-a TARGET_CPU_VARIANT=cortex-a53 TARGET_2ND_ARCH=arm TARGET_2ND_ARCH_VARIANT=armv7-a-neon TARGET_2ND_CPU_VARIANT=cortex-a9 HOST_ARCH=x86_64 HOST_2ND_ARCH=x86 HOST_OS=linux HOST_OS_EXTRA=Linux-5.4.0-150-generic-x86_64-Ubuntu-18.04.4-LTS HOST_CROSS_OS=windows HOST_CROSS_ARCH=x86 HOST_CROSS_2ND_ARCH=x86_64 HOST_BUILD_TYPE=release BUILD_ID=RQ1A.201205.003 OUT_DIR=out PRODUCT_SOONG_NAMESPACES=device/generic/goldfish device/generic/goldfish-opengl external/mesa3d vendor/nxp-opensource/imx/power hardware/google/pixel vendor/partner_gms hardware/google/camera vendor/nxp-opensource/imx/camera ============================================ [……] #### build completed successfully (13:07 (mm:ss)) #### After compilation, "evk_8mp-ota-eng.forlinx.zip" will be generated under "out/target/product/evk_8mp/", this is the zip file we need for the OTA upgrade. This is the zip file we need for the OTA upgrade. forlinx@ubuntu:~/imx8mp/OK8MP-android-source$ cd out/target/product/evk_8mp/ forlinx@ubuntu:~/imx8mp/OK8MP-android-source/out/target/product/evk_8mp$ ls evk* evk_8mp-ota-eng.forlinx.zip Back up ''evk_8mp-ota-eng.forlinx.zip'',re name to ''full-ota_v1.0.zip'': forlinx@ubuntu:~/imx8mp/OK8MP-android-source/out/target/product/evk_8mp$ cp evk_8mp-ota-eng.forlinx.zip full-ota_v1.0.zip forlinx@ubuntu:~/imx8mp/OK8MP-android-source/out/target/product/evk_8mp$ ls full* full-ota_v1.0.zip After completing steps 1 and 2, you can modify the source code according to actual needs. After the modification is completed, follow steps 1 and 2 again, at this time the new "evk_8mp-target_files-eng.forlinx.zip" is renamed "target_files_v2.0.zip"; "evk_8mp-ota-eng.forlinx.zip" is renamed "full-ota_eng.forlinx"; "evk_8mp-ota-eng.forlinx.zip" is renamed "full-ota_eng.forlinx"."; "evk_8mp-target_files-eng.forlinx.zip", renamed to "full-target_v2.0.zip". 3. Compile incremental upgrade package The incremental update package contains only the encoding of the differences between the two files. The incremental update package can only be installed on devices using the old or source version. Before building the incremental update package, two target files need to be built. Old packages that have been applied on the device, such as the target _ files _ v1.0.zip saved earlier; The latest package waiting for the application on the device, such as the target _ files _ v2.0.zip saved earlier. In the Android environment, use the following command to generate the incremental upgrade package: forlinx@ubuntu:~/imx8mp/R3_6.28/OK8MP-android-source$ cp out/target/product/evk_8mp/obj/PACKAGING/target_files_intermediates/target_files_v* ./ forlinx@ubuntu:~/imx8mp/OK8MP-android-source$ out/host/linux-x86/bin/ota_from_target_files -i target_files_v1.0.zip target_files_v2.0.zip incremental-ota.zip Note: Copy target_files_v1.0.zip and target_files_v2.0.zip to the OK8MP-android-source directory first, otherwise the execution command will report an error. 4. Upgrade with full package (using update system from development board storage). Copy the compiled "full-ota_v1.0.zip" to a USB flash drive and extract it to get payload.bin and payload_properties.txt. Insert the USB drive into the development board. The path to the USB drive is a directory under /mnt/media_rw/ with a random name; use the actual name. In this case, it is: CA35-A916. Copy payload.bin and payload_properties.txt to the /data/ota_package directory of the development board: evk_8mp:/ $ su evk_8mp:/ # cd /data/ota_package/ evk_8mp:/data/ota_package # cp /mnt/media_rw/CA35-A916/full-ota_v1.0/payload* ./ evk_8mp:/data/ota_package # ls payload.bin payload_properties.txt View payload_properties.txt: evk_8mp:/ # cat payload_properties.txt FILE_HASH=isiQeegRKyOdi9/aazwQjrZWRAIbB1Nyj1WdZ22L3Pk= FILE_SIZE=555766395 METADATA_HASH=p0+xQATUAG7dZg/kuPaQACDdClkEOZDHoOhxx0lBEuA= METADATA_SIZE=56853 Note: The contents in different payload _ properties. txt are inconsistent, and the actual queried values are the main ones. Enter the following command on the debug serial port to update: evk_8mp:/ # update_engine_client --payload=file:///data/ota_package/payload.bin --up\ date -- headers="FILE_HASH=isiQeegRKyOdi9/aazwQjrZWRAIbB1Nyj1WdZ22L3Pk= FILE_SIZE=555766395 METADATA_HASH=p0+xQATUAG7dZg/kuPaQACDdClkEOZDHoOhxx0lBEuA= METADATA_SIZE=56853" Description: payload specifies the upgrade file,/data/ota _ package/payload. bin is the path to the file. headers is the file information of the upgrade file, which is obtained from the payload _ properties. txt. Note: When entering commands, ensure that values enclosed within double quotes, such as FILE_HASH, are entered on a new line. The system automatically executes the command that follows after recognizing the backtick. Also, make sure that you do not add any spaces after each value, as adding spaces may cause errors in parsing. After the input is completed, the update _ engine _ client will be automatically upgraded in the background. You can use the following command to view the progress. evk_8mp:/ # logcat -s update_engine [……] 08-08 16:38:33.926 569 569 I update_engine: [INFO:update_attempter_android.cc(535)] Update successfully applied, waiting to reboot. [……] The above message indicates that the upgrade is complete. Restart the development board to switch to the new system. 5. Upgrade with incremental packages Note on incremental upgrades: An incremental upgrade is an upgrade between two target files, replacing only the parts that differ between the two targets. The same code generates different target files each time. For example, if the current code commit is A, and you have used the ''target files'' command multiple times to generate A1, A2, and A3, then after modifying the code, the code becomes B, and using the ''target files'' command generates B1. If at this point the program on the board is identical to target files A1, then the incremental package generated with A1 and B1 can be successfully upgraded. However, the incremental packages generated with A2 and A3 and B1 cannot be successfully upgraded due to a hash value verification failure in the partition. When creating and performing an upgrade using the incremental package method, upgrade failures often occur, primarily due to the reasons mentioned above. In order for the upgrade to be successful, it is necessary to ensure that the system's internal programs are identical to the old target files used to generate the upgrade package. Flashing the system is done via image writing, so the hash values of the various partitions will differ from those of the target file we generated. Consequently, if an incremental upgrade is to be used, the initial upgrade must be performed with a full package, and the target file corresponding to this full package must be preserved as the foundation for the subsequent incremental upgrade. Subsequently, the target file from each upgrade must be retained as the basis for the next incremental upgrade. If the hash values within the system do not match those required by the incremental package, a full package upgrade is needed to establish the correct correspondence. So, the incremental upgrade tests were all incremental upgrade tests after a full upgrade had been completed. The incremental upgrade steps are the same as the full package upgrade, just follow step 4.
  2. The default display orientation for the Android interface on the Forlinx Embedded i.MX8MP platform is landscape, but some products may require a portrait display. To address this requirement, Forlinx Embedded provides the following methods for modification: The Android system controls the screen orientation through the persist.vendor.orientation property, which can have values of 0, 90, 180, or 270. Configuration path: frameworks/native/services/su**ceflinger/Su**ceFlinger.cpp Modify in processDisplayHotplugEventsLocked: Su**ceFlinger::processDisplayHotplugEventsLocked() { continue; } + /* Rotate desktop */ + char rotationvalue[PROPERTY_VALUE_MAX] = "";; + property_get("persist.vendor.orientation", rotationvalue, "-1"); + int rotation = atoi(rotationvalue); + ALOGI("Primary Display Orientation is set to rotation %2d.", rotation); + switch (rotation) { + case 0: + internalDisplayOrientation = ui::ROTATION_0; + break; + case 90: + internalDisplayOrientation = ui::ROTATION_90; + break; + case 180: + internalDisplayOrientation = ui::ROTATION_180; + break; + case 270: + internalDisplayOrientation = ui::ROTATION_270; + break; + default: + break; + } + const DisplayId displayId = info->id; const auto it = mPhysicalDisplayTokens.find(displayId); After modification, you need to add the relevant configuration in the environment variable. Path: device/nxp/imx8m/evk_8mp/system.prop persist.sys.timezone=Asia/Shanghai persist.sys.language=zh persist.sys.country=CN +persist.vendor.orientation=90 Rotate 90 degrees here to write 90, 180 degrees to write 180, 270 degrees to write 270. If you encounter a failure to set the value of a property: Add the followings in device/nxp/imx8m/sepolicy/property_contexts; +persist.vendor.orientation u:object_r:debug_prop:s0 vendor.wc_transport. u:object_r:vendor_wc_prop:s0 persist.vendor.usb.config u:object_r:vendor_usb_config_prop:s0 vendor.usb.config u:object_r:vendor_usb_config_prop:s0
  3. In this article, we will introduce the SoMs of the Allwinner series. Allwinner × Forlinx Embedded The cooperation between Forlinx Embedded and Allwinner Technology started in 2019. Up to now, Forlinx Embedded has launched 3 SoMs based on Allwinner processors--FETT507-C, FETA40i-C, and FETT3-C that won unanimous recognition of the market. 01 Allwinner T507 Series FETT507-C SoM is designed and developed based on Allwinner T507 quad-core industrial level processor Cortex-A53 with main frequency 1.5GHz, integrated with G31 GPU, 2GB DDR3L RAM, and 8GB eMMC storage. With Linux, Android, and Forlinx Desktop operating systems, it is suitable for in-vehicle electronics, power, medical care, industrial control, IoT, intelligent terminals, and other fields. 02 Allwinner A40i Series The FETA40i-C SoM is designed based on Allwinner industrial control level processor quad-core Cortex-A7 A40i with main frequency 1.2GHz, integrated with MAli400MP2 GPU, 1GB/2GB DDR3L RAM, 8GB eMMC storage. It supports most current popular video and image formats decoding and has the advantages of stable and reliable industrial-level product performance, cost-effective and low-power consumption, etc. Equipped with Linux and Android operating systems, it is suitable for industrial control products based on visual interaction. 03 Allwinner T3 Series FETT3-C SoM is designed and developed based on Allwinner quad-core car navigation processor Cortex-A7 with main frequency 1.2GHz, integrated with MAli400MP2 GPU, 1GB DDR3L RAM, 8GB eMMC storage. Entire board industrial level running temperature supports most current popular video and image formats decoding and has the advantages of stable and reliable industrial-level product performance, low-power consumption, rich interfaces etc. Equipped with Linux and Android operating systems, it is suitable for in-vehicle electronics, power, medical care, industrial control, IoT, intelligent terminals, and other fields. Above is the big list of Forlinx Embedded’s Allwinner series; the industrial-level quality makes the application more stable and reliable.
  4. I have just started with the youtube channel, so I decided to make a Bluetooth controlled robotic car. As am an electronics engineer I have knowledge about electronics. but I don't know how to build a custom android application. so Before making the project I learn about MIT app inventor and try to make one app which was a great success it is quite easy to do. In this article, we will learn how to make a custom Android application and how to configure the Bluetooth module with Arduino. Hardware requirements: Arduino Uno Bluetooth HC-05 l298n motor Driver acrylic sheet wheels x2 geared dc motor x2 mini breadboard 4.7k, 2.2k resistor jumper wires 12v battery 9v battery switch Step 1: Building Chassis I used an acrylic sheet length of 18cm and width of 13cm. First, I positioned all parts that going to be mounted on the chassis. then I used a hot glue gun to stick the parts to acrylic you can use spacers or screws. after mounting all parts I stick the caster wheel at the bottom of the chassis. Step 2: Connection Make the connection according to the circuit diagram. we can use separate power for Arduino. Motor driver and 12v battery connected through the switch. As we can see in the circuit diagram there is 2.2k and 4.7 k resistor connected to the pins of the bluetooth module. the main reason for this is the HC-05 Bluetooth module uses a logic level of 3.3v. While transmitting data from HC-05 to Arduino there is no problem because Arduino is capable of receiving data from 3.3v logic, but while receiving any data from Arduino to HC-05 Arduino uses 5v logic which may damage our Bluetooth module, to convert 5v logic level to 3.3v we use a voltage divider method. Make sure that there is common ground between motor driver and Arduino otherwise motor not work. Step 3: Programming /* Author:DIYelex date: 3/8/2019 */ #include <SoftwareSerial.h> // TX RX software library for bluetooth SoftwareSerial mySerial(2, 3); // Connect the TXD pin of BT module to pin 2 of the Arduino and the RXD pin of BT module to pin 3 of Arduino. int Rightmotor1 = 4; //pin 1 of Rightmotor int Rightmotor2 = 5; //pin2 of Rightmotor int leftmotor1 = 6;//pin1 of leftmotor int leftmotor2 = 7;//pin2 of leftmotor int en1=9; //enable pin for Rightmotor int en2=10; // enable pin for leftmotor String readString; void setup() { pinMode(Rightmotor1,OUTPUT); // attach Right Motor 1st wire to pin 4 pinMode(Rightmotor2,OUTPUT); // attach Right Motor 1st wire to pin 5 pinMode(leftmotor1,OUTPUT);// attach Right Motor 1st wire to pin 6 pinMode(leftmotor2,OUTPUT);// attach Right Motor 1st wire to pin 7 pinMode(en1,OUTPUT); //attach motor drivers rightmotor enable pin to PWM pin 9 of arduino pinMode(en2,OUTPUT);//attach motor drivers leftmotor enable pin to PWM pin 10 of arduino Serial.begin(9600); //Setup usb serial connection to computer mySerial.begin(9600);//Setup Bluetooth serial connection to android } void loop() { while(mySerial.available()){ delay(50); char data = mySerial.read();//store the data come from bluetooth to char data readString+=data; } if(readString.length() > 0) { Serial.println(readString); ///Print the data to serial monitor which is given by bluetooth if(readString == "Forward"){ //if forward received do following digitalWrite(Rightmotor1, HIGH); ////////////FORWARD //////////////////////// digitalWrite(Rightmotor2, LOW); digitalWrite(leftmotor1, HIGH); digitalWrite(leftmotor2, LOW); analogWrite(en1,200);// for controlling speed of Rightmotor vary the value from 0 to 255 analogWrite(en2,200);// for controlling speed of leftmotor vary the value from 0 to 255 } if(readString == "Back"){ //if Back received do following digitalWrite(Rightmotor1, LOW); ////////////BACK///////////////////////////// digitalWrite(Rightmotor2, HIGH); digitalWrite(leftmotor1, LOW); digitalWrite(leftmotor2, HIGH); analogWrite(en1,200); analogWrite(en2,200); } if(readString == "Left"){ //if left received do following digitalWrite(Rightmotor1, HIGH);/////////////LEFT//////////////////////////// digitalWrite(Rightmotor2, LOW); digitalWrite(leftmotor1, LOW); digitalWrite(leftmotor2, HIGH); analogWrite(en1,80); analogWrite(en2,80); } if(readString == "Right"){ //if Right received do following digitalWrite(Rightmotor1, LOW);/////////////RIGHT//////////////////////// digitalWrite(Rightmotor2, HIGH); digitalWrite(leftmotor1, HIGH); digitalWrite(leftmotor2, LOW); analogWrite(en1,80); analogWrite(en2,80); } if(readString == "Stop"){ //if stop received do following digitalWrite(Rightmotor1, LOW); ///////////stop///////////////// digitalWrite(Rightmotor2, LOW); digitalWrite(leftmotor1, LOW); digitalWrite(leftmotor2, LOW); } readString = ""; } } Step 4: Android App Now we have to build Bluetooth applications that would be capable of controlling your robot car. If you wish to download my application you can download it from github: The Bluetooth car How I created this application was through App Inventor 2, The images above show both the "Designer" & "Block" view of my application so you can build and change thing up if you wish! Steps for configuring bluetooth First turn on the switch of robot car Go to setting Click on the Bluetooth TabTurn Bluetooth on Wait for your phone to find the HC-05 Bluetooth module Once it has been found click it and input the password by default it should be either "1234" or "0000" Now open the application Bluetooth car Application and click the " Bluetooth image" button You should see the HC-05 Module (If not re-try the steps above) click on the Module The Application will then return automatically to the main screen and you can see the green text "connected" At this point, the HC-05 Modules Red LED should now be constantly on instead of pulsing meaning a device is currently connected. Conclusion Thanks for Reading watch this project video on youtube https://youtu.be/iC7P9nyFu9I
×
  • Create New...