Giter VIP home page Giter VIP logo

ribasco / ucgdisplay Goto Github PK

View Code? Open in Web Editor NEW
14.0 4.0 2.0 82.19 MB

A character/graphics lcd library for single board computers (e.g. Raspberry Pi) written in Java. Provides drivers for graphics monochrome display devices (lcd, oled, e-ink etc) powered by U8g2

License: GNU Lesser General Public License v3.0

Java 21.11% CMake 0.84% C++ 33.07% Shell 0.14% FreeMarker 0.01% C 44.59% Objective-C 0.25%
graphics display lcd hd44780 oled i2c spi parallel raspberry-pi arm

ucgdisplay's Issues

Maven artifact stuck on "1.4.1"

Hi Rafael.
Following your work from behind ๐Ÿ‘
Noticed that the Maven artifact are still stuck on 1.4.1, not 1.5.0 as indicated by the readme.
Maybe are there some glitches in the Travis deploy script?

Kind regards

Getting 'java.lang.UnsatisfiedLinkError: Can't find dependent libraries' when using snapshots built by Travis

When in virtual mode, it seems that running snapshot versions built by Travis CI throws 'java.lang.UnsatisfiedLinkError: C:\Users\raffy\AppData\Local\Temp\ucgdisp4751649856605482962.dll: Can't find dependent libraries'.

However, using a locally built snapshot (same version) cross-compiled from my Ubuntu machine do not have this issue and works as expected.

Need to investigate this further.

[Native] Exception in thread "main" java.lang.UnsatisfiedLinkError

Error running from Raspberry Pi:

Exception in thread "main" java.lang.UnsatisfiedLinkError: /tmp/libucgdisp7530612871061594713.so: /tmp/libucgdisp7530612871061594713.so: undefined symbol: _Z21cb_byte_8bit_6800modeP11u8g2_info_tP11u8x8_structhhPv
	at java.lang.ClassLoader$NativeLibrary.load(Native Method)
	at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1941)
	at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1824)
	at java.lang.Runtime.load0(Runtime.java:809)
	at java.lang.System.load(System.java:1086)
	at org.scijava.nativelib.NativeLoader.loadLibrary(NativeLoader.java:126)
	at com.ibasco.ucgdisplay.core.utils.NativeLibraryLoader.loadLibrary(NativeLibraryLoader.java:53)
	at com.ibasco.ucgdisplay.core.u8g2.U8g2Graphics.<clinit>(U8g2Graphics.java:160)
	at com.ibasco.ucgdisplay.drivers.glcd.GlcdBaseDriver.initialize(GlcdBaseDriver.java:132)
	at com.ibasco.ucgdisplay.drivers.glcd.GlcdDriver.<init>(GlcdDriver.java:58)
	at com.ibasco.ucgdisplay.drivers.glcd.GlcdDriver.<init>(GlcdDriver.java:49)
	at com.ibasco.ucgdisplay.drivers.glcd.GlcdDriver.<init>(GlcdDriver.java:41)
	at com.ibasco.ucgdemo.Demo.main(Demo.java:22)

Wrong arch identifier for macosx

The native library would throw an exception due to the library not being found. It is currently using the search path of 'lib/mac/amd64'. The actual arch identifier used is x86_64, so the path should be lib/mac/x86_64

java: symbol lookup error: **.so: undefined symbol: spi_setup

Ran a test on Raspberry Pi 2. Error thrown during initialization.

21:37:52.225 [main] DEBUG com.ibasco.ucgdisplay.drivers.glcd.GlcdConfig - Using display setup procedure (Display: D_128x64, Protocol: SPI_HW_4WIRE_ST7920, Setup Proc: u8g2_Setup_st7920_s_128x64_f))
21:37:52.332 [main] DEBUG com.ibasco.ucgdisplay.common.utils.PidispJniExtractor - [JNI-EXTRACT #1]: Searching in path: /usr/java/packages/lib/arm:/lib:/usr/lib/libucgdisp.so
21:37:52.378 [main] DEBUG com.ibasco.ucgdisplay.common.utils.PidispJniExtractor - [JNI-EXTRACT] Os Name = linux, Os Arch = arm, Os version = 4.14.71-v7+
21:37:52.400 [main] DEBUG com.ibasco.ucgdisplay.common.utils.PidispJniExtractor - [JNI-EXTRACT #2] Searching in path: lib/linux/arm/
21:37:52.401 [main] DEBUG org.scijava.nativelib.BaseJniExtractor - mappedLib is libucgdisp.so
21:37:52.402 [main] DEBUG org.scijava.nativelib.BaseJniExtractor - URL is jar:file:/home/pi/IdeaProjects/ucg-demo/lib/ucgd-native-graphics-1.1-alpha-20181029.065708-1.jar!/lib/linux/arm/libucgdisp.so
21:37:52.403 [main] DEBUG org.scijava.nativelib.BaseJniExtractor - URL path is file:/home/pi/IdeaProjects/ucg-demo/lib/ucgd-native-graphics-1.1-alpha-20181029.065708-1.jar!/lib/linux/arm/libucgdisp.so
21:37:52.484 [main] DEBUG org.scijava.nativelib.BaseJniExtractor - Extracting 'jar:file:/home/pi/IdeaProjects/ucg-demo/lib/ucgd-native-graphics-1.1-alpha-20181029.065708-1.jar!/lib/linux/arm/libucgdisp.so' to '/tmp/libucgdisp5693912452735116357.so'
java: symbol lookup error: /tmp/libucgdisp5693912452735116357.so: undefined symbol: spi_setup

Add/Implement getNativeBuffer in U8g2Graphics interface

The u8g2 2.7 update now provides the capability to process/manipulate the pixel buffer directly.

TODO:

Add a new method in U8g2Graphics which returns a bytebuffer instance that wraps around the native pixel buffer allocated off-heap.

  • getNativeBuffer()

Port code generation tool to Java

Issues with the current code generation tool

  • Needs to be re-compiled every time the controller header file (controller.h) has been updated.
  • Requires a local copy of the u8g2 repository for it to work
  • Not ci-friendly

Notes:

  • Port the cpp code of the gen tool to java. Should be in it's own separate module and packaged as a runnable jar.
  • All new controller/font data should be fetched directly from the u8g2 repository (master branch) via Github API.
  • Consider automating the code generation when a new display controller has been added/updated in the u8g2 repository.

Add travis-ci support

Make sure that

  • Project java sources are compiled/packaged correctly
  • Cross-compilation of native library (Linux/Windows) works

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.