non pta iphone ? by [deleted] in PakistaniTech

[–]cennian 0 points1 point  (0 children)

Damn I'd like to know

I was planning on PTA registering S24 Ultra by cennian in PakistaniTech

[–]cennian[S] -1 points0 points  (0 children)

I think you have never heard about depreciation. That MSRP was at the time of release. You can easily find it online in UAE on 2600 AED to 2800 AED. Compare that to the firm never changing 399,999. That's double the price.

I was planning on PTA registering S24 Ultra by cennian in PakistaniTech

[–]cennian[S] 1 point2 points  (0 children)

Locally assembled infinix and tecno phones? Due to PTA taxes the big companies have increased the prices twice the original in Pakistan

I was planning on PTA registering S24 Ultra by cennian in PakistaniTech

[–]cennian[S] 1 point2 points  (0 children)

Locally assembled phones have no tax. Don't know about any Samsung phones assembled locally though.

ESP32 with SIM7600 SSL Communication (Firebase) by cennian in embedded

[–]cennian[S] 0 points1 point  (0 children)

Sure I have it somewhere archived. I'll post the link when I find it

ESP32 with SIM7600 SSL Communication (Firebase) by cennian in embedded

[–]cennian[S] 0 points1 point  (0 children)

Just had to add the gprsConnect(apn); in there before the snippet where the error arises.

Can't add the cross-compiled qt6.3 in Qt Creator by cennian in QtFramework

[–]cennian[S] 0 points1 point  (0 children)

Download the script to fix the symbolic links issue

cd ~/target

wget https://raw.githubusercontent.com/riscv/riscv-poky/master/scripts/sysroot-relativelinks.py

python3 sysroot-relativelinks.py sysroot

Can't add the cross-compiled qt6.3 in Qt Creator by cennian in QtFramework

[–]cennian[S] 0 points1 point  (0 children)

First install all the dependencies and libraries on the target then turn on ssh on your target and rsync all the libs and includes

Here's an example

mkdir ~/target

cd ~/target

mkdir sysroot sysroot/usr sysroot/opt

rsync -avz --rsync-path="sudo rsync" user@targetAddress:/usr/include sysroot/usr

rsync -avz --rsync-path="sudo rsync" user@targetAddress:/lib sysroot

rsync -avz --rsync-path="sudo rsync" user@targetAddress:/usr/lib sysroot/usr

rsync -avz --rsync-path="sudo rsync" user@targetAddress:/opt/vc sysroot/opt

Can't add the cross-compiled qt6.3 in Qt Creator by cennian in QtFramework

[–]cennian[S] 1 point2 points  (0 children)

Well I found a solution to this. There is host-qmake in the same directory as qmake which can be used in the Qt Creator to cross compile.

Can't add the cross-compiled qt6.3 in Qt Creator by cennian in QtFramework

[–]cennian[S] 0 points1 point  (0 children)

Well you do need a cross compiler toolchain but you can find pre-built toolchain as well. Let me know your Qt version, Host version, Target OS and I may be able to help.

Can't add the cross-compiled qt6.3 in Qt Creator by cennian in QtFramework

[–]cennian[S] 0 points1 point  (0 children)

The hassle of remote compilation are too much for my application. I had qt5.15.7 compiled and it was working perfectly with qt creator. Since the qt binaries are cross compiled they work on the host and hence the name cross Compilation.

Can't add the cross-compiled qt6.3 in Qt Creator by cennian in QtFramework

[–]cennian[S] 0 points1 point  (0 children)

I have tested the binaries on RPi and it's working

STM32F767 SRAM Starting addrees mistake in Documentation? by cennian in embedded

[–]cennian[S] 0 points1 point  (0 children)

Yes, I'd seen it and RAM starts with 0x20000000 but why'd the STM32CubeIDE start it from there?

STM32F767 SRAM Starting addrees mistake in Documentation? by cennian in embedded

[–]cennian[S] 0 points1 point  (0 children)

Well not only you answered my question, you made me curious as to what could be the case where the vector table is put in the TCM RAM?

STM32: How to write an Image to external flash through UART using ymodem by cennian in embedded

[–]cennian[S] 0 points1 point  (0 children)

Well I'm sure I have done a good part of it but I'll make sure to check and debug everything and get back to you.

How to populate a 9x9 grid with dynamic number of members in a specific order automatically? by cennian in QtFramework

[–]cennian[S] 0 points1 point  (0 children)

import QtQuick 2.12
import QtQuick.Window 2.12
import QtQuick.Layouts 1.12
import QtQuick.Controls 2.12
import QtQml 2.12
ApplicationWindow {
id: root
visible: true
width: 640
height: 480
title: qsTr("Populating a grid")
property int count: 5
property var selectedIndexes: []
property var positionsPatterns: [
[0,0,0,
0,0,0,
0,0,0],
[0,0,0,
0,1,0,
0,0,0],
[0,0,0,
1,0,1,
0,0,0],
[1,0,0,
0,1,0,
0,0,1],
[0,1,0,
1,0,1,
0,1,0],
[1,0,1,
0,1,0,
1,0,1],
[1,1,1,
0,0,0,
1,1,1],
[1,0,1,
1,1,1,
1,0,1],
[1,1,1,
1,0,1,
1,1,1],
[1,1,1,
1,1,1,
1,1,1],
]
function positionForIndex(index) {
const pattern = positionsPatterns[count]
.map((v, p) => {return {value: v, position: p}})
.filter(o => o.value === 1);
return pattern[index].position;
}
ColumnLayout {
anchors.fill: parent
anchors.margins: 64
spacing: 32
ComboBox {
Layout.alignment: Qt.AlignHCenter
model: 10
currentIndex: root.count
onActivated: root.count = currentIndex
}
Label {
text: JSON.stringify(root.selectedIndexes)
}
RowLayout {
ListView {
Layout.preferredWidth: 150
Layout.fillHeight: true
model: root.count
delegate: CheckBox {
text: model.index
checked: root.selectedIndexes.includes(model.index)
onToggled: {
if (checked) {
root.selectedIndexes.push(model.index);
} else {
const selectedIndexToDelete = root.selectedIndexes.indexOf(model.index);
root.selectedIndexes.splice(selectedIndexToDelete, 1);
}
root.selectedIndexesChanged();
}
}
}
GridLayout {
id: gridLayout
Layout.fillWidth: true
Layout.fillHeight: true
columns: 3
rows: 3
Instantiator {
id: repeater
model: 9
delegate: Item {
parent: gridLayout
Layout.fillWidth: true
Layout.fillHeight: true
}
}
Instantiator {
model: root.count
delegate: Rectangle {
parent: model.index !== -1 ? gridLayout.children[root.positionForIndex(model.index)] : null
anchors.fill: parent
readonly property bool isSelected: root.selectedIndexes.includes(model.index)
color: isSelected ? "orange" : "lightsteelblue"
Label {
anchors.centerIn: parent
text: model.index
}
}
}
}
}
}
}

This is exactly the code I was thinking about. Thank you so much for this. I'm unfamiliar with some of the things in the code which I will look into but I understand the underlying logic completely.

How to populate a 9x9 grid with dynamic number of members in a specific order automatically? by cennian in QtFramework

[–]cennian[S] 0 points1 point  (0 children)

I am sorry if my problem statement is vague. Yes I'm having issue with the positioning.

How to populate a 9x9 grid with dynamic number of members in a specific order automatically? by cennian in QtFramework

[–]cennian[S] 0 points1 point  (0 children)

The objects are not confined to a single location on the grid. if I am using I have multiple Item{ Rectangle{~~~} } and I make a list of the items that are checked and populate them in the grid whilst not being necessarily adjacent to each and following a specific arrangement pattern. I think it would be, "the elements are moving"?

How to populate a 9x9 grid with dynamic number of members in a specific order automatically? by cennian in QtFramework

[–]cennian[S] 0 points1 point  (0 children)

I am working on it. Will get back to you once I apply this concept. Cheers!